//
//  cfatores.cpp
//  complexidade
//  https://br.spoj.pl/problems/CFATORES/
//  Created by Bruno Dias on 05/07/11.
//  Copyright 2011 __MyCompanyName__. All rights reserved.
//

#include <iostream>

using namespace std;

#define MAX 1000001

int main() {
    int ehprimo[MAX];
    for (int i = 2; i <= MAX; i++) {
        ehprimo[i] = i%2;
    }
    for (int i = 3; i*i <= MAX; i = i + 2) {
        if (ehprimo[i] && i < 32768) {
            for (int j = i; j*j <= MAX; j = j + 2) {
                ehprimo[j] = 0;
            }
        }
    }
    ehprimo[1] = 0;
    ehprimo[2] = 1;
    int x;
    while (cin >> x && x != 0) {
        int i = 2;
        int n = 0; 
        bool b = false;
        int num = x;
        while (i <= 50000 && i <= num) {
            if ((num % i != 0)) {
                i++;
                b = false;
            } else {
                if (b == false) {
                    n++;
                }
                num = num / i;
                b = true;
            }
        }
        if (ehprimo[num]) {
            n++;
        }
        cout << x << " : " << n << "\n";
    }
}
